package com.itheima.demo09.ConstructorMethodReference;

public class Demo {
    public static void main(String[] args) {
        printName("迪丽热巴", name -> new Person(name));
        printName("迪丽热巴", Person::new);
    }

    public static void printName(String name, PersonBuilder pb) {
        Person person = pb.builderPerson(name);
        System.out.println(person.getName());
    }
}
